<?php
  class Plugins_Bookdata extends model {
  
  
  
  function getformadd($productid="")
  {
  
//$code  = '<div class="itPlg">'."\n";

//$code .= '</div>';
  
  $code  = '<form class="wrpNewPlg">'."\n";
$code .= '<fieldset class="BookDtPlg">'."\n";
$code .= '<div class="bookDtPlg fs04 clTxt2">'."\n";
$code .= '<div class="hdNewPlg">'."\n";
$code .= '<span class="boldGen">Book Detail</span>'."\n";
$code .= '</div>'."\n";
$code .= '<div class="bdNewPlg">'."\n";
$code .= '<div class="wrpInpNewPrcPlg">'."\n";
$code .= '<div class="inpNewPrcPlg clBg3 clBd2 bdFull">'."\n";
$code .= '<div class="pdAppPlg">'."\n";
$code .= '<span>Product in App</span>'."\n";
$code .= '<input type="text" name="pinapp[]" class="inpAddCtnt w120 clBg5 clBd2 fs03 clTxt2">'."\n";
$code .= '</div>'."\n";
$code .= '<div class="pdAppPlg">'."\n";
$code .= '<span>Author</span>'."\n";
$code .= '<input type="text" name="author[]" class="inpAddCtnt w120 clBg5 clBd2 fs03 clTxt2">'."\n";
$code .= '</div>'."\n";
$code .= '<div class="pdAppPlg">'."\n";
$code .= '<span>Publisher</span>'."\n";
$code .= '<input type="text" name="publisher[]" class="inpAddCtnt w120 clBg5 clBd2 fs03 clTxt2">'."\n";
$code .= '</div>'."\n";
$code .= '</div>'."\n";
$code .= '</div>'."\n";
$code .= '</div>'."\n";
$code .= '</div>'."\n";
$code .= '</fieldset>'."\n";
$code .= '</form>';
  
  $arraydata['form']=addslashes(str_replace(array("\r", "", "\r"), '', $code));
 // $arraydata['js'][]=pluginjsinfo.'/upload.js';


  
  
      
  
  
  
  return $arraydata;
  
  
  
  
  
  
  
  }
  
  function getformlanding($arraydata)
  {
    $code="";


    $data['str']=$code;
    $data['target']='secondtarget';

    return $data;
  
  
  }
  
  function getplugin($plugreid)
  {
  
  $sql="select * from tb_plugins_bookdata where plugreid=".$plugreid;
  $arrayplugin=$this->db->db_set_1recordrow($sql);



  
  
  return $arrayplugin;
  

  
  
  

  
  }
  
  function saveplugin($arraydata,$productid,$plugreid)
  {
  $arraydata['productid']=$productid;
  $arraydata['plugreid']=$plugreid;

  $this->db->db_set($arraydata,'tb_plugins_bookdata');
  
  }
  
  
  }
?>
